/**
 * package: seeds
 * author: zhaiyujin
 * description:
 */
package seeds

import (
	"gorm.io/gorm"

	"huanteng/web/models"
)

func SeedRoleMenu(db *gorm.DB)  {

	role_menu:=[]models.RoleMenu{}
	var lenght,i int64

	db.Model(models.Menu{}).Count(&lenght)
	for i=1;i<=lenght;i++{
		role_menu=append(role_menu,models.RoleMenu{RoleID:2,MenuID:uint(i)})
	}
	db.Create(&role_menu)

}
